<form class="form-horizontal form-validate form-modal" method="post" action="{:url('check')}">
    <div class="modal-dialog">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal">&times;</button>
                <h4 class="modal-title">升级审核</h4>
            </div>
            <div class="modal-body">

                <div class="form-group">
                    <div class="col-sm-6">
                        <label class="col-sm-3 control-label">升级方式：</label>
                        <div class="col-sm-5 m-t-mc">
                            {$row['type']==1?'业绩':'保证金'}
                        </div>
                    </div>
                </div>
                <div class="form-group">
                    <div class="col-sm-6">
                        <label class="col-sm-3 control-label">状态：</label>
                        <div class="col-sm-5 m-t-mc red">
                            {$status[$row['status']]}
                        </div>
                    </div>
                    <div class="col-sm-6">
                        <label class="col-sm-3 control-label">申请日期：</label>
                        <div class="col-sm-5 m-t-mc">
                            {$row.add_time|dateTpl}
                        </div>
                    </div>
                </div>
                <div class="form-group">
                    <div class="col-sm-6">
                        <label class="col-sm-3 control-label">会员名称：</label>
                        <div class="col-sm-5 m-t-mc">
                            <a href="{:url('sys_admin.users/info',['user_id'=>$row['user_id']])}" data-toggle="wrapperAjax">{$row.user_id}-{$row.user_id|userInfo=true,'real_name'}</a>
                        </div>
                    </div>
                    <div class="col-sm-6">
                        <label class="col-sm-3 control-label">推荐上级：</label>
                        <div class="col-sm-5 m-t-mc">
                            <a href="{:url('sys_admin.users/info',['user_id'=>$row['pid']])}" data-toggle="wrapperAjax">{$row.pid}-{$row.pid|userInfo=true,'real_name'}</a>
                        </div>
                    </div>
                </div>
                <div class="form-group">
                    <div class="col-sm-6">
                        <label class="col-sm-3 control-label">升级层级：</label>
                        <div class="col-sm-5 m-t-mc red">
                           {$proxyLevel[$row['up_proxy_id']]['proxy_name']}
                        </div>
                    </div>
                    <div class="col-sm-6">
                        <label class="col-sm-3 control-label">当前层级：</label>
                        <div class="col-sm-5 m-t-mc green">
                            {$proxyLevel[$row['proxy_id']]['proxy_name']}
                        </div>
                    </div>
                </div>

                <div class="form-group">
                    <div class="col-sm-6">
                        <label class="col-sm-3 control-label">新供货上级：</label>
                        <div class="col-sm-5 m-t-mc">
                            {if condition="$row.new_supply_uid > 0"}
                            <a href="{:url('sys_admin.users/info',['user_id'=>$row['new_supply_uid']])}" data-toggle="wrapperAjax">{$row.new_supply_uid} - {$row.new_supply_uid|userInfo=true,'real_name'}</a>
                            {else/}
                            厂家
                            {/if}
                        </div>
                    </div>
                    <div class="col-sm-6">
                        <label class="col-sm-3 control-label">现供货上级：</label>
                        <div class="col-sm-5 m-t-mc">
                            <a href="{:url('sys_admin.users/info',['user_id'=>$row['supply_uid']])}" data-toggle="wrapperAjax">{$row.supply_uid}-{$row.supply_uid|userInfo=true,'real_name'}</a>
                        </div>
                    </div>
                </div>

                <div class="form-group">
                    <div class="col-sm-6">
                        <label class="col-sm-3 control-label">电子合同：</label>
                        <div class="col-sm-5 m-t-mc">
                            {if condition="$row.userinfo.contract neq ''"}
                                <a href="{$row.userinfo.contract}" target = "_blank" title="查看" class="fa m-xs">查看</a>
                            {else/}
                                查看
                            {/if}
                        </div>
                    </div>
                    <div class="col-sm-6">
                        <label class="col-sm-3 control-label">上级电子合同：</label>
                        <div class="col-sm-5 m-t-mc">
                            {if condition="$row.newuserinfo.contract neq ''"}
                            <a href="{$row.newuserinfo.contract}" target = "_blank" title="查看" class="fa m-xs">查看</a>
                            {else/}
                            查看
                            {/if}
                        </div>
                    </div>
                </div>

                <div class="form-group">
                    <label class="col-sm-2 control-label">备注：</label>
                    <div class="col-sm-9">
                        <textarea name="admin_note" id="admin_note" style="width:100%; height:80px;">{$row['admin_note']}</textarea>
                    </div>
                </div>

                {eq name="row.type" value="2"}
                <div class="form-group">
                    <label class="col-sm-3 control-label">保证金凭证：</label>
                    <div class="col-sm-9 " style="height: 30px;line-height: 30px">
                        <img src="{$row.bond_voucher}" style="width: 300px;height: 200px;">
                    </div>
                </div>
                {/eq}
                {gt name="row.check_uid" value="0"}
                <div class="form-group">
                    <label class="col-sm-3 control-label">操作管理员：</label>
                    <div class="col-sm-6 m-t-mc">
                        {$row.check_uid} - {$row.check_uid|adminInfo}
                    </div>
                </div>
                {/gt}
                {gt name="row.check_time" value="0"}
                <div class="form-group">
                    <label class="col-sm-3 control-label">审核时间：</label>
                    <div class="col-sm-6 m-t-mc">
                        {$row.check_time|dateTpl}
                    </div>
                </div>
                {/gt}

            </div>
            <div class="modal-footer">
                <input type="hidden" name="log_id" value="{$row.log_id|intval}"/>
                <input type="hidden" name="operating" id="operating" value="note"/>
                {eq name="row.status" value="0"}
                    <button type="button" class="btn btn-primary operatbtn" data-type='refuse'>拒绝申请</button>
                    <button type="button" class="btn btn-primary operatbtn" data-type='ok'>审核通过</button>
                {/eq}
                <button type="submit" class="btn btn-primary postBtn hide" data-loading-text="保存中..." disabled>保存</button>
                <button type="button" class="btn btn-default" data-dismiss="modal">取消</button>
            </div>
        </div>
    </div>
</form>
